using System.ComponentModel.DataAnnotations;
using Newtonsoft.Json;

namespace WebPrinter.Library.DaQu.Params
{
    /// <summary>
    /// 添加打印机参数
    /// </summary>
    public class PrinterAddParam
    {
        /// <summary>
        /// 打印机编号
        /// </summary>
        [Required]
        [StringLength(50)]
        [JsonProperty("sn")]
        public string Sn { get; set; }

        /// <summary>
        /// 设备密钥
        /// </summary>
        [Required]
        [StringLength(255)]
        [JsonProperty("key")]
        public string Key { get; set; }

        /// <summary>
        /// 设备名称或备注
        /// </summary>
        [StringLength(50)]
        [JsonProperty("name")]
        public string Name { get; set; }

        /// <summary>
        /// 语言类型（1~16）
        /// </summary>
        [Range(1, 16)]
        [JsonProperty("lang")]
        public int? Lang { get; set; }
    }
}